<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
<script>
    /**对象的属性 方法*/
    var dog = {
        //属性
        dogName:"lily",
        weight:"20kg",
        color:"black",
        age:2,
        //方法 是一种数据类型
        jump:function(){
            //some action
            if(this.age>=2){
                console.log(this.dogName + "can jump");
            }
        }
    }
    /**
     * 定义一个cat对象，属性有名字 品种 体重
     * 
    */
   var cat = {
       //属性
       catName :"miaomiao",
       kind:"xiaomao",
       weight:"5kg"
   }
</script>
</html>